package edu.ynu.se.xiecheng.achitectureclass.dao;
import edu.ynu.se.xiecheng.achitectureclass.entity.AirTemperatureData;
import edu.ynu.se.xiecheng.achitectureclass.entity.CarbonDioxideData;
import edu.ynu.se.xiecheng.achitectureclass.entity.SoilNitrogenData;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;

public interface AirTemperatureDataDao extends JpaRepository<AirTemperatureData, Long>{
    List<AirTemperatureData> findAll();
    AirTemperatureData findTopByOrderByCreateTimeDesc();

    // 获取土壤温度历史数据（分页）
    Page<AirTemperatureData> findAllByOrderByCreateTimeDesc(Pageable pageable);
}
